Stabilize skill loader test isolation#1161
Conversation
jatmn
left a comment
There was a problem hiding this comment.
Findings
- [P2] Keep the isolated skill filter type-safe
src/skills/loadSkillsDir.test.ts:37
The new predicate dereferences optionalskillRoot, and the combined predicate no longer leavespromptSkillsnarrowed to prompt commands for the laterskillRootassertions.bun x tsc --noEmit --pretty falsenow reports errors in this touched test file forskill.skillRootpossibly being undefined and forskillRootnot existing on non-prompt commands. Please guardskillRootand keep the filtered array narrowed to prompt commands, for example with an explicit type predicate plus optional chaining.
Blockers
Non-Blocking
Looks Good
Verdict: Changes Requested — type safety issue needs to be fixed. |
|
Confirmed @jatmn's point. The new isolated-skill predicate dereferences optional |
|
Updated the filter to guard optional |
Summary
loadSkillsDir.test.tsto the temp fixture skills root.Validation
bun test src/skills/loadSkillsDir.test.tsNotes
This is a tiny test-only cleanup from a fork. No runtime behavior changes.